package com.explore.demo.mapper;

import com.explore.demo.pojo.DeliveryLog;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author gaolainan
 * @since 2021-05-15
 */
public interface DeliveryLogMapper extends BaseMapper<DeliveryLog> {

    /**
     * 获得当前用户 发布的职位 别人投递的记录
     * @param id
     * @return
     */
    @Select("select * from delivery_log where recruit_id in (select u.id from recruitment u where human_source_id = #{id})")
    public List<DeliveryLog> getDeliveryByHumanSourceId(Integer id);

}
